const requireEx=require('yi-require');
const $ = requireEx('yi-schema');

module.exports = {
  body: $.object({
      _id:$.mongoid().required().description('ID'),
      pid:$.mongoid().description("父节点ID"),
      name:$.string().min(1).description("菜单名称"),
      component:$.string().min(1).description("component"),
      redirect:$.string().min(1).description("redirect"),
      path :$.string().min(1).description("path"),
      title:$.string().description('标题'),
      icon : $.string().description('图标'),
      img : $.string().description('网络图片地址'),
      ord:$.number().integer().required().positive().description('排序')
  })
};